package com.haidong.component;

import javax.swing.*;
import java.awt.*;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;

public class HelpPanel extends JPanel {
    public HelpPanel() {
        super(new GridLayout(5,3));
        for (int i = 0; i < 4; i++) {
            add(new JLabel(""));
        }
        JLabel tip = new JLabel("本系统设计的很浅显易懂了,如果还是不会操作,请按下面的按钮联系我");
        tip.setFont(new Font("dialog",0,20));
        add(tip);
        for (int i = 0; i < 2; i++) {
            add(new JLabel(""));
        }

        JPanel mid = new JPanel(new GridLayout(3,3));
        for (int i = 0; i < 4; i++) {
            mid.add(new JLabel(""));
        }
        JButton button = new JButton("push me!");
        button.setFont(new Font("dialog",0,20));
        mid.add(button);
        for (int i = 0; i < 4; i++) {
            mid.add(new JLabel(""));
        }

        add(mid);
        for (int i = 0; i < 2; i++) {
            add(new JLabel(""));
        }
        JLabel label = new JLabel("");
        label.setFont(new Font("dialog",0,20));
        add(label);
        for (int i = 0; i < 4; i++) {
            add(new JLabel(""));
        }
        button.addActionListener(new ActionListener() {
            @Override
            public void actionPerformed(ActionEvent e) {
                label.setText("我的微信的是17629901709,想学,我教你呀");
            }
        });
    }
}
